package wapper;

import wapper.componet.AbstractLogger;
import wapper.componet.impl.Logger;
import wapper.drcorator.impl.LineLoggerDecorator;
import wapper.drcorator.impl.StarLoggerDecorator;

public class Main {
    public static void main(String[] args) {
        AbstractLogger mLogger = new Logger();
        System.out.println("无包装");
        mLogger.print("刘小军");
        AbstractLogger lineLoger = new LineLoggerDecorator(mLogger);
        System.out.println("1层包装");
        lineLoger.print("刘小军");
        System.out.println("2层包装");
        AbstractLogger nestLogger = new StarLoggerDecorator(lineLoger);
        nestLogger.print("刘小军");
    }
}
